package com.kui.web;

import java.io.IOException;
import java.util.List;

import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.kui.entity.Wenxian;
import com.kui.service.WenxianService;

public class WxServlet extends HttpServlet {

	
	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;

	public void doGet(HttpServletRequest request, HttpServletResponse response)
			throws ServletException, IOException {

		WenxianService ws = new WenxianService();
		List<Wenxian> wenxianlist = ws.findAll();
		request.setAttribute("wenxianlist", wenxianlist);
		request.getRequestDispatcher("WEB-INF/views/wenxian.jsp").forward(request, response);
	}

}
